package com.banggood.upms.config;

import com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter;
import org.springframework.boot.autoconfigure.web.HttpMessageConverters;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.http.converter.HttpMessageConverter;

/**
 * @author XuChuangFeng
 * @date 2017/7/14
 */
@Configuration
public class FastJSONConfig {

    @Bean
    public HttpMessageConverters customConverters() {
        HttpMessageConverter<?> additional = new FastJsonHttpMessageConverter();
        return new HttpMessageConverters(additional);
    }

}